import {postRequest} from "@/utils/request";
import {getRequest} from "@/utils/request";
/**
 * 根据条件查询系部信息
 */
 export function selectMajorApi(data) {
  return postRequest(
   "/major/selectMajor",
    data
  );
}

/**
* 根据角色有权限的菜单
*/
export function selectMajorMenuApi(data) {
return postRequest(
 "/major/selectMajorMenu",
  data
);
}

/**
* 根据角色有权限的菜单
*/
export function selectUserMajorApi(data) {
  return postRequest(
   "/major/selectUserMajor",
    data
  );
}

/**
* 修改角色状态
*/
export function updateMajorStatusApi(data) {
  return postRequest(
   "/major/updateMajorStatus",
    data
  );
}

/**
* 修改系部所属学院
*/
export function updateMajorCollegeCodeApi(data) {
  return postRequest(
   "/major/updateMajorCollegeCode",
    data
  );
}

/**
* 删除系部
*/
export function deleteMajorApi(data) {
  return postRequest(
   "/major/deleteMajor",
    data
  );
}
/**
* 新增所属学院
*/
export function getcollegeCodeApi(data) {
  return getRequest(
   "/major/getcollegeCode",
    data
  );
}

/**
* 新增教师
*/
export function getceachCodeApi(data) {
  return getRequest(
   "/major/getceachCode",
    data
  );
}

/**
* 修改角色权限
*/
export function cancelMajorUserApi(data) {
  return postRequest(
   "/major/cancelMajorUser",
    data
  );
}

/**
* 修改角色菜单
*/
export function updateMajorMenuApi(data) {
  return postRequest(
   "/major/updateMajorMenu",
    data
  );
}

/**
* 修改系部信息
*/
export function updateMajorApi(data) {
  return postRequest(
   "/major/updateMajor",
    data
  );
}

/**
* 添加系部
*/
export function addMajorApi(data) {
  return postRequest(
   "/major/addMajor",
    data
  );
}